home *** CD-ROM | disk | FTP | other *** search
/ Chip 2001 December / Chip_2001-12_cd1.bin / zkuste / tuning / download / xteq / setup.exe / {app} / plugins / XQ Startmenu Options.xpl < prev    next >
Text File  |  2001-04-13  |  6KB  |  206 lines

  1. "FILE"="Xteq Systems X-Setup Plugin 5.0"
  2. "TYPE"="9"
  3. "COUNT"="1"
  4. "UIPATH"="Appearance\Start menu\Options"
  5. "NAME"="Display Options"
  6. "VERSION"="2.03"
  7. "LANGUAGE"="VBScript"
  8. "TEXT 1"="LONG plug-in..."
  9. "DESCRIPTION 1"="If an item is disabled (not checked), Windows will either not display it or will not allow that change are made."
  10. "DESCRIPTION 2"="NOTE #1: If you disable the context menu for Start->Programs, you will not be able to use drag & drop to move the items inside Programs."
  11. "AUTHOR"="Neil R. Turner (totalxs@hotmail.com) for Xteq Systems"
  12. "CONTACTURL"="http://www.neilrt.cwc.net/"
  13. "COPYRIGHT"="Copyright ⌐ Xteq Systems - All Rights Reserved"
  14. "COMMENT 1"="'Multiple Columns' setting from Tom Simpson [thomas@mail.xenafan.com] - thanks a lot!"
  15. "COMMENT 2"="Thanks to Ken [k-o@cyberdude.dk] for the "no drag&drop" notice."
  16. "COMMENT 3"="Thanks to Jon-Roar Selenius [jseleniu@online.no] for spotting the "Recent Documents always empty" bug."
  17. "COMMENT 4"="Thanks to Thomas Zundel [Thomas.Zundel@htp-tel.de] for the "third option not working" bug notice!"
  18. "COMMENT 5"="Thanks to Pierre Szwarc [szwarc@usa.net] for some of the settings!"
  19. "COMMENT 6"="Thanks to Ojatex [ojatex@aol.com] for the code for the Recent Docs Shortcuts setting!"
  20.  
  21.  ' Paths
  22.  sPA="HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer\"
  23.  sPB="HKLM\Software\Microsoft\Windows\CurrentVersion\Advanced\"
  24.  sPC="HKCU\Software\Microsoft\Windows\CurrentVersion\Advanced\"
  25.  ' Values
  26.  sA1="NoTrayContextMenu" ' DWORD
  27.  sA2="NoChangeStartMenu" ' DWORD
  28.  sA3="NoRecentDocsHistory" ' BIN
  29.  sA4="NoStartMenuSubFolders" ' DWORD
  30.  sA5="NoCommonGroups" ' DWORD
  31.  sB1="StartMenuScrollPrograms" ' $ (false/true)
  32.  sC1="StartMenuScrollPrograms" ' $ (yes/empty)
  33.  sC2="IntelliMenus" ' $ (yes/empty)
  34.  sC3="StartMenuAdminTools" ' $ (yes/empty)
  35.  ' Variables
  36.  IE="HKLM\Software\Microsoft\Internet Explorer\Version"
  37.  w=GetWinVer
  38.  
  39. SUB Plugin_Initialize
  40.  ' we use s for reading the changeable values
  41.  ' and i for variables (IE version etc.)
  42.  
  43.  ' sA1 (universal)
  44.  Call SetUIElement(1,"Enable right-click context menu for System tray")
  45.  s=RegReadValue(sPA&sA1)
  46.  if s=0 OR IsEmpty(s) then
  47.   Call SetUIElementEx(1,true)
  48.  end if
  49.  
  50.  ' sA2 (IE4)
  51.  i=RegReadValue(IE)
  52.  if i>"4" then
  53.   Call SetUIElement(2,"Enable right-click context menu for Start Menu")
  54.   s=RegReadValue(sPA&sA2)
  55.   if s=0 OR IsEmpty(s) then
  56.    Call SetUIElementEx(2,true)
  57.   end if
  58.  end if
  59.  
  60.  ' sA3 (IE4)
  61.  i=RegReadValue(IE)
  62.  if i>"4" then
  63.   Call SetUIElement(3,"Create Recent Document shortcuts on the Documents sub-menu")
  64.   s=RegReadValue(sPA&sA3)
  65.   if s=0 OR IsEmpty(s) then
  66.    Call SetUIElementEx(3,true)
  67.   end if
  68.  end if
  69.  
  70.  ' sA4 (Universal)
  71.  Call SetUIElement(4,"Show user-created folders at top of Start Menu")
  72.  s=RegReadValue(sPA&sA4)
  73.  if s=0 OR IsEmpty(s) then
  74.   Call SetUIElementEx(4,true)
  75.  end if
  76.  
  77.  ' sA5 (NT/2K)
  78.  if w=2 OR w=4 then
  79.   Call SetUIElement(5,"Show Common Groups in Start -> Programs")
  80.   s=RegReadValue(sPA&sA5)
  81.   if s=0 OR IsEmpty(s) then
  82.    Call SetUIElementEx(5,true)
  83.   end if
  84.  end if
  85.  
  86.  ' sB1 (9x/NT)
  87.  if w<4 then
  88.   Call SetUIElement(6,"Show Start->Programs with Multiple Columns")
  89.   s=RegReadValue(sPB&sB1)
  90.   if s="false" then
  91.    Call SetUIElementEx(6,true)
  92.   end if
  93.  end if
  94.  
  95.  ' sC1 (2K/Me)
  96.  if w>3 then
  97.   Call SetUIElement(7,"Show Start->Programs with Multiple Columns")
  98.   s=RegReadValue(sPC&sC1)
  99.   if s="NO" then
  100.    Call SetUIElementEx(7,true)
  101.   end if
  102.  end if
  103.  
  104.  ' sC2 (2K/Me)
  105.  if w>3 then
  106.   Call SetUIElement(8,"Use Personalized Menus (hide unused items)")
  107.   s=RegReadValue(sPC&sC2)
  108.   if s="YES" then
  109.    Call SetUIElementEx(8,true)
  110.   end if
  111.  end if
  112.  
  113.  ' sC3 (2K)
  114.  if w=4 then
  115.   Call SetUIElement(9,"Show Administrative Tools folder")
  116.   s=RegReadValue(sPC&sC3)
  117.   if s="YES" then
  118.    Call SetUIElementEx(9,true)
  119.   end if
  120.  end if
  121. END SUB
  122.  
  123. SUB Plugin_Apply(ElementIndex,ElementSubIndex)
  124.  ' sA1
  125.  b=GetUIElementEx(1)
  126.  if b=true then
  127.   Call RegWriteValue(sPA&sA1,0,2)
  128.  else
  129.   Call RegWriteValue(sPA&sA1,1,2)
  130.  end if
  131.  
  132.  ' sA2
  133.  b=GetUIElementEx(2)
  134.  if b=true then
  135.   Call RegWriteValue(sPA&sA2,0,2)
  136.  else
  137.   Call RegWriteValue(sPA&sA2,1,2)
  138.  end if
  139.  
  140.  ' sB1 (part of original plug-in code)
  141.  b=GetUIElementEx(6)
  142.  if b=true then
  143.   Call RegWriteValue(sPB&sB1,"false",1)
  144.  else
  145.   Call RegWriteValue(sPB&sB1,"true",1)
  146.  end if
  147.  
  148.  ' sA3
  149.  b=GetUIElementEx(3)
  150.  if b=true then
  151.   Call RegWriteValue(sPA&sA3,"00000000",3)
  152.  else
  153.   Call RegWriteValue(sPA&sA3,"01000000",3)
  154.  end if
  155.  
  156.  ' sA4
  157.  b=GetUIElementEx(4)
  158.  if b=true then
  159.   Call RegWriteValue(sPA&sA4,0,2)
  160.  else
  161.   Call RegWriteValue(sPA&sA4,1,2)
  162.  end if
  163.  
  164.  ' sA5
  165.  b=GetUIElementEx(5)
  166.  if b=true then
  167.   Call RegWriteValue(sPA&sA5,0,2)
  168.  else
  169.   Call RegWriteValue(sPA&sA5,1,2)
  170.  end if
  171.  
  172.  ' sC1
  173.  b=GetUIElementEx(7)
  174.  if b=true then
  175.     Call RegWriteValue(sPC&sC1,"NO",1)
  176.  else
  177.     Call RegWriteValue(sPC&sC1,"YES",1)
  178.  end if
  179.  
  180.  ' sC2
  181.  b=GetUIElementEx(8)
  182.  if b=true then
  183.     Call RegWriteValue(sPC&sC2,"YES",1)
  184.  else
  185.     Call RegWriteValue(sPC&sC2,"NO",1)
  186.  end if
  187.  
  188.  ' sC3
  189.  b=GetUIElementEx(9)
  190.  if b=true then
  191.     Call RegWriteValue(sPC&sC3,"YES",1)
  192.  else
  193.     Call RegWriteValue(sPC&sC3,"NO",1)
  194.  end if
  195.  
  196.  ' At least they all use IndicateSettingChange() !
  197.  Call IndicateSettingChange()
  198. END SUB
  199.  
  200. SUB Plugin_Terminate
  201.  ' All Your Tweaks Are Belong To Us
  202.  ' You are on the way to reconfiguration
  203.  ' You have no setings to survive make your time
  204.  ' Ha ha ha ha ...
  205. END SUB
  206.